package com.heima.wemedia.thread;

import com.heima.model.wemedia.pojos.WmUser;

/**
 * @author :28169
 * @date : 2022/7/15 15:05
 */
public class USerThreadLocal  {
    //Threadlocal类型静态变量

     public static ThreadLocal<WmUser> threadLocal= new ThreadLocal<>();

     //变量对应的get和set方法
    public static WmUser get(){
        return threadLocal.get();
    }
    public static void set(WmUser wmUser){
        threadLocal.set(wmUser);
    }

    //变量对应的remove
    public void remove(){
        threadLocal.remove();
    }

}
